﻿@model IEnumerable<ZDSoft.LMS.Domain.TransportOrder>
@{
    ViewBag.Title = "Index";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
<link href="@Url.Content("~/Content/Style/ViewPage.css")" rel="stylesheet" type="text/css" />
<table border="0" cellpadding="0" cellspacing="0" style="width: 100%; background-color: White;"
    align="center">
    <tr>
        <td class="mbg">
            <table cellspacing="0" cellpadding="0" width="100%" border="0" valign="top">
                <tr>
                    <td>
                        <table style="height: 23px;" cellspacing="0" cellpadding="0" width="120" background="@Url.Content("~/Content/Images/m_17.gif")"
                            border="0">
                            <tr>
                                <td>
                                    <span class="contentPageTitle">&nbsp;&gt;&gt; 货物运单管理</span>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
                <tr>
                    <td align="right" class="titleContentDivider" height="6">
                    </td>
                </tr>
            </table>
        </td>
    </tr>
</table>
<p>
    @Html.ActionLink("创建", "Create")
</p>
<table cellpadding="0" cellspacing="0" class="dataGrid">
    <tr>
        <th>
            发站
        </th>
        <th>
            到站（局）
        </th>
        <th>
            发货地点
        </th>
        <th>
            交货地点
        </th>
        <th>
            托运人名称
        </th>
        <th>
            托运人电话
        </th>
        <th>
            收货人名称
        </th>
        <th>
            收货人电话
        </th>
        <th>
            操作
        </th>
    </tr>
        @if (Model == null || Model.Count() == 0)
        { 
        <td colspan="9">没有满足条件的数据！</td>
        }
        else
        {
            foreach (var item in Model)
            {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item.StartStation)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Destionation)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.StartStationLocation)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.DeliveryLocation)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Commisionedor.Name)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Commisionedor.Telephone)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Receiver.Name)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Receiver.Telephone)
            </td>
            <td>
                @Html.ActionLink("编辑", "Edit", new { id = item.ID }) |
                @Html.ActionLink("详细信息", "Details", new { id = item.ID }) |
                @Html.ActionLink("删除", "Delete", new { id = item.ID })
            </td>
        </tr>
            }
        }
</table>
